#pragma once

#include "FCProperties.h"

namespace UIStone
{
	class FCController_Position : public FCPropertyContainer
		<
			Loki::TL::MakeTypelist
			<
				FCPropertyPositionMode,
				FCPropertyX,
				FCPropertyY,
				FCPropertyXPercent,
				FCPropertyYPercent,
				FCPropertyXIsRight,
				FCPropertyYIsBottom,
				FCPropertyZIndex
			>::Result
		>
	{
	public:
		enum PositionType
		{
			POSITION_STATIC		= 0,
			POSITION_ABSOLUTE	= 1,
			POSITION_RELATIVE	= 2
		};

		enum ZIndexType
		{
			Z_INDEX_AUTO		= -1,
			Z_INDEX_BOTTOM		= 0,
			Z_INDEX_TOP			= LONG_MAX
		};

		FCController_Position()
		{
			_defaultValue();
		}

		virtual ~FCController_Position() {}

	private:
		void _defaultValue()
		{
			PositionMode() = POSITION_STATIC;
			ZIndex() = Z_INDEX_AUTO;
			X() = Y() = XPercent() = YPercent() = 0;
			XIsRight() = YIsBottom() = false;
		}
	};
};